@@ Local IDs apply to all floors (not lobby or roof)
@.equ LOCALID_TRAINER_DOUBLES1, 2
@.equ LOCALID_TRAINER_SINGLES,  3
@.equ LOCALID_TRAINER_KNOCKOUT, 4
@.equ LOCALID_TRAINER_DOUBLES2, 5

@.equ HIDE_TRAINER_DOUBLES1, FLAG_TEMP_2
@.equ HIDE_TRAINER_SINGLES,  FLAG_TEMP_3
@.equ HIDE_TRAINER_KNOCKOUT, FLAG_TEMP_4
@.equ HIDE_TRAINER_DOUBLES2, FLAG_TEMP_5
@.equ HIDE_OWNER,            FLAG_TEMP_6

@.equ DISABLE_SINGLES_TRIGGER,  VAR_TEMP_E
@.equ DISABLE_DOUBLES_TRIGGER,  VAR_TEMP_F


@@@ Map scripts

TrainerTower_OnResume:: @ 81C4F54
@	setvar VAR_TEMP_2, 0
@	ttower_resumetimer
    end

TrainerTower_OnTransition:: @ 81C4F62
@	ttower_initfloor
@	switch VAR_RESULT
@	case CHALLENGE_TYPE_SINGLE, TrainerTower_EventScript_SetObjectsSingles
@	case CHALLENGE_TYPE_DOUBLE, TrainerTower_EventScript_SetObjectsDoubles
@	case CHALLENGE_TYPE_KNOCKOUT, TrainerTower_EventScript_SetObjectsKnockout
@	setflag HIDE_TRAINER_DOUBLES1
@	setflag HIDE_TRAINER_SINGLES
@	setflag HIDE_TRAINER_KNOCKOUT
@	setflag HIDE_TRAINER_DOUBLES2
@	setvar DISABLE_SINGLES_TRIGGER, TRUE
@	setvar DISABLE_DOUBLES_TRIGGER, TRUE
    end

TrainerTower_EventScript_SetObjectsSingles:: @ 81C4FA7
@	setflag HIDE_TRAINER_DOUBLES1
@	setflag HIDE_TRAINER_KNOCKOUT
@	setflag HIDE_TRAINER_DOUBLES2
@	setvar DISABLE_DOUBLES_TRIGGER, TRUE
@	setobjectxyperm       LOCALID_TRAINER_SINGLES, 15, 13
@	setobjectmovementtype LOCALID_TRAINER_SINGLES, MOVEMENT_TYPE_FACE_LEFT
@	goto TrainerTower_EventScript_HideOwner

TrainerTower_EventScript_SetObjectsDoubles:: @ 81C4FC5
@	setflag HIDE_TRAINER_SINGLES
@	setflag HIDE_TRAINER_KNOCKOUT
@	setvar DISABLE_SINGLES_TRIGGER, TRUE
@	ttower_isfloorcleared
@	compare VAR_RESULT, TRUE
@	goto_if_eq TrainerTower_EventScript_SetObjectsDoublesAlreadyBeaten
@	setobjectxyperm       LOCALID_TRAINER_DOUBLES1, 10, 12
@	setobjectmovementtype LOCALID_TRAINER_DOUBLES1, MOVEMENT_TYPE_FACE_LEFT
@	setobjectxyperm       LOCALID_TRAINER_DOUBLES2, 10, 13
@	setobjectmovementtype LOCALID_TRAINER_DOUBLES2, MOVEMENT_TYPE_FACE_LEFT
@	goto TrainerTower_EventScript_HideOwner

TrainerTower_EventScript_SetObjectsDoublesAlreadyBeaten:: @ 81C4FFE
@	setobjectxyperm       LOCALID_TRAINER_DOUBLES1, 10, 12
@	setobjectmovementtype LOCALID_TRAINER_DOUBLES1, MOVEMENT_TYPE_FACE_DOWN
@	setobjectxyperm       LOCALID_TRAINER_DOUBLES2, 11, 12
@	setobjectmovementtype LOCALID_TRAINER_DOUBLES2, MOVEMENT_TYPE_FACE_DOWN
@	goto TrainerTower_EventScript_HideOwner

@@ Knockout challenge re-uses trainer objects
TrainerTower_EventScript_SetObjectsKnockout:: @ 81C5019
@	setflag HIDE_TRAINER_DOUBLES2
@	setvar DISABLE_DOUBLES_TRIGGER, TRUE
@	setobjectxyperm       LOCALID_TRAINER_DOUBLES1, 10, 10
@	setobjectmovementtype LOCALID_TRAINER_DOUBLES1, MOVEMENT_TYPE_FACE_DOWN
@	setobjectxyperm       LOCALID_TRAINER_SINGLES, 14, 13
@	setobjectmovementtype LOCALID_TRAINER_SINGLES, MOVEMENT_TYPE_FACE_LEFT
@	setobjectxyperm       LOCALID_TRAINER_KNOCKOUT, 10, 16
@	setobjectmovementtype LOCALID_TRAINER_KNOCKOUT, MOVEMENT_TYPE_FACE_UP
TrainerTower_EventScript_HideOwner:
@	setflag HIDE_OWNER
    end

TrainerTower_OnFrame:: @ 81C5046
@	map_script_2 VAR_TEMP_2, 0, TrainerTower_EventScript_EnterFloor
@	.2byte 0

TrainerTower_EventScript_EnterFloor:: @ 81C5050
@	setvar VAR_TEMP_2, 1
@	ttower_isfloorcleared
@	compare VAR_RESULT, FALSE
@	goto_if_eq TrainerTower_EventScript_EndEnterFloor
@	setvar DISABLE_SINGLES_TRIGGER, TRUE
@	setvar DISABLE_DOUBLES_TRIGGER, TRUE
TrainerTower_EventScript_EndEnterFloor:
@	ttower_shouldexit
@	compare VAR_RESULT, TRUE
@	goto_if_eq TrainerTower_EventScript_WarpToLobby
    end

@@ Never reached
TrainerTower_EventScript_WarpToLobby:: @ 81C5086
@	warp MAP_TRAINER_TOWER_LOBBY, 255, 9, 7
@	waitstate


@@@ Battle scripts

TrainerTower_EventScript_TriggerBattle::
@	ttower_getchallengetype
@	switch VAR_RESULT
@	case CHALLENGE_TYPE_SINGLE, TrainerTower_EventScript_DoSingleBattle
@	case CHALLENGE_TYPE_DOUBLE, TrainerTower_EventScript_DoDoubleBattle
@	case CHALLENGE_TYPE_KNOCKOUT, TrainerTower_EventScript_DoKnockoutBattle

TrainerTower_EventScript_DoSingleBattle:
@	ttower_encountermusic
@	applymovement LOCALID_TRAINER_SINGLES, Movement_ExclamationMark
@	waitmovement 0
@	applymovement LOCALID_TRAINER_SINGLES, Movement_Delay48
@	waitmovement 0
@	setvar DISABLE_SINGLES_TRIGGER, TRUE
@	applymovement LOCALID_TRAINER_SINGLES, TrainerTower_Movement_SingleTrainerApproach
@	waitmovement 0
@	ttower_getspeech TRAINER_TOWER_TEXT_INTRO, 0
@	msgbox gStringVar4
@	closemessage
@	goto TrainerTower_EventScript_DoBattle

TrainerTower_EventScript_DoDoubleBattle:: @ 81C510D
@	ttower_getspeech TRAINER_TOWER_TEXT_INTRO, VAR_TEMP_3
@	msgbox gStringVar4
@	setvar VAR_0x8004, TRAINER_TOWER_FUNC_GET_SPEECH
@	setvar VAR_0x8005, TRAINER_TOWER_TEXT_INTRO
@	addvar VAR_TEMP_3, 1
@	compare VAR_TEMP_3, 1
@	goto_if_eq TrainerTower_EventScript_DoSecondTrainerIntro
@	setvar VAR_TEMP_3, 0
TrainerTower_EventScript_DoSecondTrainerIntro:
@	copyvar VAR_0x8006, VAR_TEMP_3
@	special CallTrainerTowerFunc
@	msgbox gStringVar4
@	closemessage
@	goto TrainerTower_EventScript_DoBattle

TrainerTower_EventScript_DoKnockoutBattle:: @ 81C515C
@	switch VAR_TEMP_1
@	case 0, TrainerTower_EventScript_DoKnockoutBattle1
@	case 1, TrainerTower_EventScript_DoKnockoutBattle2
@	case 2, TrainerTower_EventScript_DoKnockoutBattle3

TrainerTower_EventScript_DoKnockoutBattle1:
@	ttower_encountermusic
@	applymovement LOCALID_TRAINER_KNOCKOUT, Movement_ExclamationMark
@	waitmovement 0
@	applymovement LOCALID_TRAINER_KNOCKOUT, Movement_Delay48
@	waitmovement 0
@	applymovement LOCALID_TRAINER_KNOCKOUT, TrainerTower_Movement_BottomKnockoutTrainerApproach
@	waitmovement 0
@	goto TrainerTower_EventScript_DoKnockoutBattleIntro

TrainerTower_EventScript_DoKnockoutBattle2:: @ 81C51AD
@	ttower_encountermusic
@	applymovement LOCALID_TRAINER_DOUBLES1, Movement_ExclamationMark
@	waitmovement 0
@	applymovement LOCALID_TRAINER_DOUBLES1, Movement_Delay48
@	waitmovement 0
@	applymovement LOCALID_TRAINER_DOUBLES1, TrainerTower_Movement_TopKnockoutTrainerApproach
@	waitmovement 0
@	goto TrainerTower_EventScript_DoKnockoutBattleIntro

TrainerTower_EventScript_DoKnockoutBattle3:: @ 81C51D8
@	ttower_encountermusic
@	applymovement LOCALID_TRAINER_SINGLES, Movement_ExclamationMark
@	waitmovement 0
@	applymovement LOCALID_TRAINER_SINGLES, Movement_Delay48
@	waitmovement 0
@	applymovement LOCALID_TRAINER_SINGLES, TrainerTower_Movement_RightKnockoutTrainerApproach
@	waitmovement 0
TrainerTower_EventScript_DoKnockoutBattleIntro:
@	ttower_getspeech TRAINER_TOWER_TEXT_INTRO, VAR_TEMP_1
@	msgbox gStringVar4
@	closemessage
TrainerTower_EventScript_DoBattle:
@	ttower_dobattle
@	waitstate
@	switch VAR_RESULT
@	case B_OUTCOME_WON, TrainerTower_EventScript_WonBattle
@	case B_OUTCOME_LOST, TrainerTower_EventScript_WarpToLobbyLost
@	case B_OUTCOME_DREW, TrainerTower_EventScript_WarpToLobbyLost
TrainerTower_EventScript_WonBattle:
@	ttower_getchallengetype
@	switch VAR_RESULT
@	case CHALLENGE_TYPE_SINGLE, TrainerTower_EventScript_SetFloorCleared
@	case CHALLENGE_TYPE_DOUBLE, TrainerTower_EventScript_MoveDoublesTrainers
@	case CHALLENGE_TYPE_KNOCKOUT, TrainerTower_EventScript_CheckNextKnockoutBattle

TrainerTower_EventScript_CheckNextKnockoutBattle:
@	switch VAR_TEMP_1
@	case 0, TrainerTower_EventScript_DoSecondKnockoutBattle
@	case 1, TrainerTower_EventScript_DoThirdKnockoutBattle
@	case 2, TrainerTower_EventScript_MoveLastKnockoutTrainer

TrainerTower_EventScript_DoSecondKnockoutBattle:
@	addvar VAR_TEMP_1, 1
@	goto TrainerTower_EventScript_DoKnockoutBattle

TrainerTower_EventScript_DoThirdKnockoutBattle:: @ 81C52B0
@	addvar VAR_TEMP_1, 1
@	goto TrainerTower_EventScript_DoKnockoutBattle

TrainerTower_EventScript_MoveDoublesTrainers:: @ 81C52BA
@	applymovement LOCALID_TRAINER_DOUBLES2, TrainerTower_Movement_DoublesTrainer2OutOfWay
@	waitmovement 0
@	applymovement LOCALID_TRAINER_DOUBLES1, TrainerTower_Movement_DoublesTrainer1FaceDown
@	goto TrainerTower_EventScript_SetFloorCleared

TrainerTower_EventScript_MoveLastKnockoutTrainer:: @ 81C52D0
@	applymovement LOCALID_TRAINER_SINGLES, TrainerTower_Movement_LastKnockoutTrainerOutOfWay
TrainerTower_EventScript_SetFloorCleared:
@	ttower_clearedfloor
    end

TrainerTower_EventScript_WarpToLobbyLost:: @ 81C52E0
@	special HealPlayerParty
@	ttower_setlost
@	warp MAP_TRAINER_TOWER_LOBBY, 255, 9, 7
@	waitstate


@@@ Speaking to trainers after battle

TrainerTower_EventScript_SpeakToDoublesTrainer1:: @ 81C52F4
@	ttower_getchallengetype
@	switch VAR_RESULT
@	case CHALLENGE_TYPE_SINGLE, TrainerTower_EventScript_DoublesTrainer1PostBattle
@	case CHALLENGE_TYPE_DOUBLE, TrainerTower_EventScript_DoublesTrainer1PostBattle
@	case CHALLENGE_TYPE_KNOCKOUT, TrainerTower_EventScript_KnockoutTrainer2PostBattle
TrainerTower_EventScript_DoublesTrainer1PostBattle:
@	setvar VAR_0x8006, 0
@	goto TrainerTower_EventScript_DoPostBattleText

TrainerTower_EventScript_KnockoutTrainer2PostBattle:: @ 81C5331
@	setvar VAR_0x8006, 1
@	goto TrainerTower_EventScript_DoPostBattleText

TrainerTower_EventScript_SpeakToSinglesTrainer:: @ 81C533B
@	ttower_getchallengetype
@	switch VAR_RESULT
@	case CHALLENGE_TYPE_SINGLE, TrainerTower_EventScript_SinglesTrainerPostBattle
@	case CHALLENGE_TYPE_DOUBLE, TrainerTower_EventScript_SinglesTrainerPostBattle
@	case CHALLENGE_TYPE_KNOCKOUT, TrainerTower_EventScript_KnockoutTrainer3PostBattle
TrainerTower_EventScript_SinglesTrainerPostBattle:
@	setvar VAR_0x8006, 0
@	goto TrainerTower_EventScript_DoPostBattleText

TrainerTower_EventScript_KnockoutTrainer3PostBattle:: @ 81C5378
@	setvar VAR_0x8006, 2
@	goto TrainerTower_EventScript_DoPostBattleText

TrainerTower_EventScript_SpeakToKnockoutTrainer:: @ 81C5382
@	setvar VAR_0x8006, 0
@	goto TrainerTower_EventScript_DoPostBattleText

TrainerTower_EventScript_SpeakToDoublesTrainer2:: @ 81C538C
@	setvar VAR_0x8006, 1
TrainerTower_EventScript_DoPostBattleText:
@	ttower_getspeech TRAINER_TOWER_TEXT_AFTER
@	lock
@	faceplayer
@	msgbox gStringVar4
@	release
@	return


@@@ Speaking to owner

TrainerTower_EventScript_SpeakToOwner:: @ 81C53AA
@	lock
@	faceplayer
@	ttower_getownerstate
@	switch VAR_RESULT
@	case 0, TrainerTower_Roof_EventScript_Arrived
@	case 1, TrainerTower_Roof_EventScript_GivePrize
@	case 2, TrainerTower_Roof_EventScript_OwnerEnd

TrainerTower_Roof_EventScript_Arrived:
@	msgbox TrainerTower_Roof_Text_ImOwnerBattledPerfectly
TrainerTower_Roof_EventScript_GivePrize:
@	ttower_giveprize
@	switch VAR_RESULT
@	case 0, TrainerTower_Roof_EventScript_ReceivePrize
@	case 1, TrainerTower_Roof_EventScript_NoRoomForPrize
@	case 2, TrainerTower_Roof_EventScript_CheckFinalTime

TrainerTower_Roof_EventScript_ReceivePrize:
@	msgbox TrainerTower_Roof_Text_ThisIsForYou
@	textcolor 3
@	playfanfare MUS_LEVEL_UP
@	message Text_ObtainedTheX
@	waitfanfare
@	waitmessage
@	getstdstring 2, STDSTRING_ITEMS_POCKET
@	msgbox Text_PutItemAway
@	call EventScript_RestorePrevTextColor
@	goto TrainerTower_Roof_EventScript_CheckFinalTime

TrainerTower_Roof_EventScript_NoRoomForPrize:: @ 81C543A
@	msgbox TrainerTower_Roof_Text_ThisIsForYou
@	msgbox Text_BagIsFull
@	goto TrainerTower_Roof_EventScript_CheckFinalTime

TrainerTower_Roof_EventScript_CheckFinalTime:: @ 81C544F
@	ttower_checkfinaltime
@	switch VAR_RESULT
@	case 0, TrainerTower_Roof_EventScript_NewRecord
@	case 1, TrainerTower_Roof_EventScript_NoNewRecord
@	case 2, TrainerTower_Roof_EventScript_OwnerEnd

TrainerTower_Roof_EventScript_NewRecord:
@	msgbox TrainerTower_Roof_Text_DoneItInRecordTime
@	goto TrainerTower_Roof_EventScript_OwnerEnd

TrainerTower_Roof_EventScript_NoNewRecord:: @ 81C548A
@	msgbox TrainerTower_Roof_Text_TookSweetTimeGettingHere
TrainerTower_Roof_EventScript_OwnerEnd:
@	msgbox TrainerTower_Roof_Text_IdLikeToSeeBetterTime
@	release
@	return

TrainerTower_EventScript_ShowTime:: @ 81C549C
@	lockall
@	ttower_gettime
@	msgbox TrainerTower_Text_XMinYZSec
@	releaseall
    end


@@@ Battle triggers

TrainerTower_EventScript_SingleBattleTrigger:: @ 81C54AF
@	goto TrainerTower_EventScript_TriggerBattle

TrainerTower_EventScript_DoubleBattleTriggerTop:: @ 81C54B4
@	setvar VAR_TEMP_3, 0
@	ttower_checkdoubles
@	compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS
@	goto_if_ne TrainerTower_EventScript_IneligibleForDoubleBattle
@	ttower_encountermusic
@	applymovement LOCALID_TRAINER_DOUBLES1, Movement_ExclamationMark
@	waitmovement 0
@	applymovement LOCALID_TRAINER_DOUBLES1, Movement_Delay48
@	goto TrainerTower_EventScript_TriggerDoubleBattle

TrainerTower_EventScript_DoubleBattleTriggerBottom:: @ 81C54EA
@	setvar VAR_TEMP_3, 1
@	ttower_checkdoubles
@	compare VAR_RESULT, PLAYER_HAS_TWO_USABLE_MONS
@	goto_if_ne TrainerTower_EventScript_IneligibleForDoubleBattle
@	ttower_encountermusic
@	applymovement LOCALID_TRAINER_DOUBLES2, Movement_ExclamationMark
@	waitmovement 0
@	applymovement LOCALID_TRAINER_DOUBLES2, Movement_Delay48
TrainerTower_EventScript_TriggerDoubleBattle:
@	waitmovement 0
@	setvar DISABLE_DOUBLES_TRIGGER, TRUE
@	goto TrainerTower_EventScript_TriggerBattle

TrainerTower_EventScript_IneligibleForDoubleBattle:: @ 81C5528
@	lockall
@	playse SE_DING_DONG
@	msgbox TrainerTower_Lobby_Text_NeedTwoMonsForDouble
@	closemessage
@	applymovement OBJ_EVENT_ID_PLAYER, TrainerTower_Movement_PushPlayerBack
@	waitmovement 0
@	releaseall
    end

TrainerTower_Movement_SingleTrainerApproach:
@	walk_left
TrainerTower_Movement_RightKnockoutTrainerApproach:: @ 81C5542
@	walk_left
@	walk_left
TrainerTower_Movement_PushPlayerBack:
@	walk_left
@	step_end

TrainerTower_Movement_BottomKnockoutTrainerApproach:: @ 81C5546
@	walk_up
@	walk_up
@	step_end

TrainerTower_Movement_TopKnockoutTrainerApproach:: @ 81C5549
@	walk_down
@	walk_down
@	step_end

TrainerTower_Movement_DoublesTrainer2OutOfWay:: @ 81C554C
@	walk_right
TrainerTower_Movement_LastKnockoutTrainerOutOfWay:
@	walk_up
@	face_down
@	step_end

TrainerTower_Movement_DoublesTrainer1FaceDown:: @ 81C5550
@	face_down
@	step_end


ViridianCity_House2_EventScript_PokemonJournal:: @ 81ACD65
@	lock
@	faceplayer
@	famechecker FAMECHECKER_OAK, 3
@	famechecker FAMECHECKER_DAISY, 3
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureProfOak
@	release
    end

EventScript_PokemonJournalUnused1:: @ 81ACD8D
@	lock
@	faceplayer
@	famechecker FAMECHECKER_DAISY, 1
@	famechecker FAMECHECKER_OAK, 4
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureProfOak
@	release
    end

EventScript_PokemonJournalUnused2:: @ 81ACDB5
@	lock
@	faceplayer
@	famechecker FAMECHECKER_DAISY, 4
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureProfOak
@	release
    end

FourIsland_PokemonCenter_1F_EventScript_PokemonJournal:: @ 81ACDD0
@	lockall
@	famechecker FAMECHECKER_DAISY, 5
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureDaisyOak
@	releaseall
    end

Route4_EventScript_Boy:: @ 81ACDEA
@	lock
@	faceplayer
@	famechecker FAMECHECKER_BROCK, 3
@	msgbox Route4_Text_PeopleLikeAndRespectBrock
@	release
    end

MtMoon_1F_EventScript_BaldingMan:: @ 81ACE03
@	lock
@	faceplayer
@	famechecker FAMECHECKER_BROCK, 4
@	msgbox MtMoon_1F_Text_BrockHelpsExcavateFossils
@	release
    end

PewterCity_Museum_1F_EventScript_PokemonJournalBrock:: @ 81ACE1C
@	lockall
@	famechecker FAMECHECKER_BROCK, 5
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureBrock
@	releaseall
    end

Route20_EventScript_Camper:: @ 81ACE36
@	lock
@	faceplayer
@	famechecker FAMECHECKER_MISTY, 3
@	msgbox Route20_Text_MistyTrainsHere
@	release
    end

Route25_EventScript_Beauty:: @ 81ACE4F
@	lock
@	faceplayer
@	famechecker FAMECHECKER_MISTY, 4
@	msgbox Route25_Text_MistyHighHopesAboutThisPlace
@	release
    end

CeruleanCity_PokemonCenter_1F_EventScript_PokemonJournalMisty:: @ 81ACE68
@	lock
@	faceplayer
@	famechecker FAMECHECKER_MISTY, 5
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureMisty
@	release
    end

VermilionCity_PokemonCenter_1F_EventScript_PokemonJournalLtSurge:: @ 81ACE83
@	lockall
@	famechecker FAMECHECKER_LTSURGE, 5
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureLtSurge
@	releaseall
    end

CeladonCity_Condominiums_2F_EventScript_PokemonJournalErika:: @ 81ACE9D
@	lock
@	faceplayer
@	famechecker FAMECHECKER_ERIKA, 5
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureErika
@	release
    end

FuchsiaCity_WardensHouse_EventScript_PokemonJournalKoga:: @ 81ACEB8
@	lock
@	faceplayer
@	famechecker FAMECHECKER_KOGA, 4
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureKoga
@	release
    end

SafariZone_North_RestHouse_EventScript_BaldingMan:: @ 81ACED3
@	lock
@	faceplayer
@	famechecker FAMECHECKER_KOGA, 5
@	msgbox SafariZone_West_Text_KogaPatrolsSafariEverySoOften
@	release
    end

SaffronCity_PokemonCenter_1F_EventScript_PokemonJournalSabrina:: @ 81ACEEC
@	lock
@	faceplayer
@	famechecker FAMECHECKER_SABRINA, 4
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureSabrina
@	release
    end

CinnabarIsland_Gym_EventScript_BlaineFujiPhoto:: @ 81ACF07
@	lockall
@	famechecker FAMECHECKER_BLAINE, 4
@	famechecker FAMECHECKER_MRFUJI, 4
@	msgbox CinnabarIsland_Gym_Text_PhotoOfBlaineAndFuji
@	releaseall
    end

FiveIsland_ResortGorgeous_House_EventScript_PokemonJournal:: @ 81ACF2C
@	lockall
@	famechecker FAMECHECKER_BLAINE, 5
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureBlaine
@	releaseall
    end

FourIsland_Mart_EventScript_OldMan:: @ 81ACF46
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LORELEI, 2
@	msgbox FourIsland_Mart_Text_LoreleiGrewUpOnThisIsland
@	release
    end

FiveIsland_PokemonCenter_1F_EventScript_PokemonJournal:: @ 81ACF5F
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LORELEI, 3
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureLorelei
@	release
    end

SaffronCity_PokemonTrainerFanClub_EventScript_PokemonJournalBruno:: @ 81ACF7A
@	lock
@	faceplayer
@	famechecker FAMECHECKER_BRUNO, 2
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureBruno
@	release
    end

SevenIsland_SevaultCanyon_EventScript_BlackBelt:: @ 81ACF95
@	lock
@	faceplayer
@	famechecker FAMECHECKER_BRUNO, 5
@	msgbox SevenIsland_SevaultCanyon_Text_BrunoTrainedWithBrawly
@	release
    end

IndigoPlateau_PokemonCenter_1F_EventScript_BlackBelt:: @ 81ACFAE
@	lock
@	faceplayer
@	famechecker FAMECHECKER_AGATHA, 1
@	famechecker FAMECHECKER_AGATHA, 2
@	msgbox IndigoPlateau_PokemonCenter_1F_Text_AgathaWhuppedUs
@	release
    end

SevenIsland_PokemonCenter_1F_EventScript_PokemonJournal:: @ 81ACFD4
@	lock
@	faceplayer
@	famechecker FAMECHECKER_AGATHA, 3
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureAgatha
@	release
    end

SixIsland_Mart_EventScript_OldWoman:: @ 81ACFEF
@	lock
@	faceplayer
@	famechecker FAMECHECKER_AGATHA, 5
@	msgbox SixIsland_Mart_Text_AgathaOldestEverEliteFourMember
@	release
    end

EventScript_LanceUnused:: @ 81AD008
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LANCE, 0
@	msgbox gFameCheckerFlavorText_Lance0
@	release
    end

SaffronCity_EventScript_BattleGirlUnused:: @ 81AD021
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LANCE, 1
@	msgbox SaffronCity_Text_HowCanClubNotRecognizeLance
@	release
    end

SaffronCity_EventScript_BattleGirl:: @ 81AD03A
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LANCE, 2
@	msgbox SaffronCity_Text_HowCanClubNotRecognizeLance
@	release
    end

CeladonCity_DepartmentStore_2F_EventScript_Woman:: @ 81AD053
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LANCE, 3
@	msgbox CeladonCity_DepartmentStore_2F_Text_LanceComesToBuyCapes
@	release
    end

IndigoPlateau_PokemonCenter_1F_EventScript_PokemonJournal:: @ 81AD06C
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LANCE, 4
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureLance
@	release
    end

IndigoPlateau_PokemonCenter_1F_EventScript_CooltrainerM:: @ 81AD087
@	lock
@	faceplayer
@	famechecker FAMECHECKER_LANCE, 5
@	msgbox IndigoPlateau_PokemonCenter_1F_Text_LancesCousinGymLeaderFarAway
@	release
    end

LavenderTown_PokemonCenter_1F_EventScript_BaldingMan:: @ 81AD0A0
@	lock
@	faceplayer
@	famechecker FAMECHECKER_MRFUJI, 3
@	msgbox LavenderTown_PokemonCenter_1F_Text_HearMrFujiNotFromAroundHere
@	release
    end

CinnabarIsland_PokemonCenter_1F_EventScript_PokemonJournalMrFuji:: @ 81AD0B9
@	lock
@	faceplayer
@	famechecker FAMECHECKER_MRFUJI, 5
@	textcolor 3
@	msgbox PokemonJournal_Text_SpecialFeatureMrFuji
@	release
    end

SilphCo_5F_EventScript_Scientist:: @ 81AD0D4
@	lock
@	faceplayer
@	famechecker FAMECHECKER_GIOVANNI, 1
@	msgbox SilphCo_5F_Text_RocketBossLookingForStrongMons
@	release
    end

SilphCo_8F_EventScript_Scientist:: @ 81AD0ED
@	lock
@	faceplayer
@	famechecker FAMECHECKER_GIOVANNI, 2
@	msgbox SilphCo_8F_Text_ToRocketBossMonsAreTools
@	release
    end

@.set LOCALID_STICKER_MAN, 1

CeladonCity_GameCorner_EventScript_PhotoPrinter:: @ 81B2867
@	lockall
@	showmoneybox 0, 0, 0
@	msgbox CeladonCity_GameCorner_Text_TryPokemonPrinter, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq CeladonCity_GameCorner_EventScript_DeclinePhoto
@	checkmoney 50, 0
@	compare VAR_RESULT, FALSE
@	goto_if_eq CeladonCity_GameCorner_EventScript_NotEnoughMoneyForPhoto
@	playse SE_SHOP
@	removemoney 50, 0
@	updatemoneybox 0, 0, 0
@	waitse
@	message CeladonCity_GameCorner_Text_ChoosePrintType
@	waitmessage
@	multichoice 21, 0, MULTICHOICE_TRAINER_CARD_ICON_TINT, TRUE
@	switch VAR_RESULT
@	case 0, CeladonCity_GameCorner_EventScript_PrintTypeNormal
@	case 1, CeladonCity_GameCorner_EventScript_PrintTypeBlack
@	case 2, CeladonCity_GameCorner_EventScript_PrintTypePink
@	case 3, CeladonCity_GameCorner_EventScript_PrintTypeSepia
    end

CeladonCity_GameCorner_EventScript_PrintTypeNormal:: @ 81B28DB
@	setvar VAR_0x8004, MON_ICON_TINT_NORMAL
@	goto CeladonCity_GameCorner_EventScript_PrintPhoto
    end

CeladonCity_GameCorner_EventScript_PrintTypeBlack:: @ 81B28E6
@	setvar VAR_0x8004, MON_ICON_TINT_BLACK
@	goto CeladonCity_GameCorner_EventScript_PrintPhoto
    end

CeladonCity_GameCorner_EventScript_PrintTypePink:: @ 81B28F1
@	setvar VAR_0x8004, MON_ICON_TINT_PINK
@	goto CeladonCity_GameCorner_EventScript_PrintPhoto
    end

CeladonCity_GameCorner_EventScript_PrintTypeSepia:: @ 81B28FC
@	setvar VAR_0x8004, MON_ICON_TINT_SEPIA
@	goto CeladonCity_GameCorner_EventScript_PrintPhoto
    end

CeladonCity_GameCorner_EventScript_PrintPhoto:: @ 81B2907
@	message CeladonCity_GameCorner_Text_BigSmileForPhoto
@	waitmessage
@	playse MUS_PHOTO
@	dofieldeffect FLDEFF_UNK_45
@	delay 60
@	special UpdateTrainerCardPhotoIcons
@	msgbox CeladonCity_GameCorner_Text_PrintIsReadyCheckTrainerCard
@	hidemoneybox 0, 0
@	releaseall
    end

CeladonCity_GameCorner_EventScript_DeclinePhoto:: @ 81B2926
@	hidemoneybox 0, 0
@	releaseall
    end

CeladonCity_GameCorner_EventScript_NotEnoughMoneyForPhoto:: @ 81B292B
@	msgbox CeladonCity_GameCorner_Text_DontHaveEnoughMoney
@	hidemoneybox 0, 0
@	releaseall
    end

FourIsland_House2_EventScript_StickerMan:: @ 81B2938
@	lock
@	specialvar VAR_0x8008, StickerManGetBragFlags
@	goto_if_unset FLAG_MET_STICKER_MAN, FourIsland_House2_EventScript_MeetStickerMan
@	goto_if_set FLAG_MET_STICKER_MAN, FourIsland_House2_EventScript_StickerManAskForBrag
    end

FourIsland_House2_EventScript_MeetStickerMan:: @ 81B2951
@	setflag FLAG_MET_STICKER_MAN
@	msgbox FourIsland_House2_Text_WishICouldShowOffStickers
@	applymovement LOCALID_STICKER_MAN, Movement_FacePlayer
@	waitmovement 0
@	playse SE_PIN
@	applymovement LOCALID_STICKER_MAN, Movement_ExclamationMark
@	waitmovement 0
@	applymovement LOCALID_STICKER_MAN, Movement_Delay48
@	waitmovement 0
@	compare VAR_0x8008, 0
@	goto_if_eq FourIsland_House2_EventScript_StickerManNothingToBrag
@	message FourIsland_House2_Text_GiveYouStickerIfYouBrag
@	waitmessage
@	goto FourIsland_House2_EventScript_ChooseBrag
    end

FourIsland_House2_EventScript_StickerManAskForBrag:: @ 81B2994
@	applymovement LOCALID_STICKER_MAN, Movement_FacePlayer
@	waitmovement 0
@	goto_if_questlog EventScript_ReleaseEnd
@	special QuestLog_CutRecording
@	compare VAR_0x8008, 0
@	goto_if_eq FourIsland_House2_EventScript_NothingToBragAbout
@	message FourIsland_House2_Text_BragAboutWhatToday
@	waitmessage
@	goto FourIsland_House2_EventScript_ChooseBrag
    end

FourIsland_House2_EventScript_NothingToBragAbout:: @ 81B29C6
@	msgbox FourIsland_House2_Text_BragAboutSomethingForMe
@	release
    end

FourIsland_House2_EventScript_ChooseBrag:: @ 81B29D0
@	switch VAR_0x8008
@	case 1, FourIsland_House2_EventScript_ChooseBragHoF
@	case 2, FourIsland_House2_EventScript_ChooseBragEggs
@	case 4, FourIsland_House2_EventScript_ChooseBragLinkWins
@	case 3, FourIsland_House2_EventScript_ChooseBragHoFEggs
@	case 5, FourIsland_House2_EventScript_ChooseBragHoFLinkWins
@	case 6, FourIsland_House2_EventScript_ChooseBragEggsLinkWins
@	case 7, FourIsland_House2_EventScript_ChooseBragHofEggsLinkWins
    end

FourIsland_House2_EventScript_ChooseBragHoF:: @ 81B2A23
@	multichoice 15, 8, MULTICHOICE_HOF_QUIT, FALSE
@	switch VAR_RESULT
@	case 0, FourIsland_House2_EventScript_BragHoF
@	case 1, FourIsland_House2_EventScript_QuitBrag
@	case SCR_MENU_CANCEL, FourIsland_House2_EventScript_QuitBrag
    end

FourIsland_House2_EventScript_ChooseBragEggs:: @ 81B2A4F
@	multichoice 16, 8, MULTICHOICE_EGGS_QUIT, FALSE
@	switch VAR_RESULT
@	case 0, FourIsland_House2_EventScript_BragEggs
@	case 1, FourIsland_House2_EventScript_QuitBrag
@	case SCR_MENU_CANCEL, FourIsland_House2_EventScript_QuitBrag
    end

FourIsland_House2_EventScript_ChooseBragLinkWins:: @ 81B2A7B
@	multichoice 15, 8, MULTICHOICE_VICTORIES_QUIT, FALSE
@	switch VAR_RESULT
@	case 0, FourIsland_House2_EventScript_BragLinkWins
@	case 1, FourIsland_House2_EventScript_QuitBrag
@	case SCR_MENU_CANCEL, FourIsland_House2_EventScript_QuitBrag
    end

FourIsland_House2_EventScript_ChooseBragHoFEggs:: @ 81B2AA7
@	multichoice 15, 6, MULTICHOICE_HOF_EGGS_QUIT, FALSE
@	switch VAR_RESULT
@	case 0, FourIsland_House2_EventScript_BragHoF
@	case 1, FourIsland_House2_EventScript_BragEggs
@	case 2, FourIsland_House2_EventScript_QuitBrag
@	case SCR_MENU_CANCEL, FourIsland_House2_EventScript_QuitBrag
    end

FourIsland_House2_EventScript_ChooseBragHoFLinkWins:: @ 81B2ADE
@	multichoice 15, 6, MULTICHOICE_HOF_VICTORIES_QUIT, FALSE
@	switch VAR_RESULT
@	case 0, FourIsland_House2_EventScript_BragHoF
@	case 1, FourIsland_House2_EventScript_BragLinkWins
@	case 2, FourIsland_House2_EventScript_QuitBrag
@	case SCR_MENU_CANCEL, FourIsland_House2_EventScript_QuitBrag
    end

FourIsland_House2_EventScript_ChooseBragEggsLinkWins:: @ 81B2B15
@	multichoice 15, 6, MULTICHOICE_EGGS_VICTORIES_QUIT, FALSE
@	switch VAR_RESULT
@	case 0, FourIsland_House2_EventScript_BragEggs
@	case 1, FourIsland_House2_EventScript_BragLinkWins
@	case 2, FourIsland_House2_EventScript_QuitBrag
@	case SCR_MENU_CANCEL, FourIsland_House2_EventScript_QuitBrag
    end

FourIsland_House2_EventScript_ChooseBragHofEggsLinkWins:: @ 81B2B4C
@	multichoice 15, 5, MULTICHOICE_HOF_EGGS_VICTORIES_QUIT, FALSE
@	switch VAR_RESULT
@	case 0, FourIsland_House2_EventScript_BragHoF
@	case 1, FourIsland_House2_EventScript_BragEggs
@	case 2, FourIsland_House2_EventScript_BragLinkWins
@	case 3, FourIsland_House2_EventScript_QuitBrag
@	case SCR_MENU_CANCEL, FourIsland_House2_EventScript_QuitBrag
    end

FourIsland_House2_EventScript_StickerManNothingToBrag:: @ 81B2B8E
@	msgbox FourIsland_House2_Text_GiveYouStickerIfYouBrag
@	release
    end

FourIsland_House2_EventScript_BragHoF:: @ 81B2B98
@	compare VAR_0x8004, 39
@	goto_if_le FourIsland_House2_EventScript_BragHoFLowest
@	compare VAR_0x8004, 99
@	goto_if_le FourIsland_House2_EventScript_BragHoFLow
@	compare VAR_0x8004, 199
@	goto_if_le FourIsland_House2_EventScript_BragHoFHigh
@	compare VAR_0x8004, 200
@	goto_if_ge FourIsland_House2_EventScript_BragHoFHighest
    end

FourIsland_House2_EventScript_BragHoFLowest:: @ 81B2BC5
@	compare VAR_HOF_BRAG_STATE, 1
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedHoF
@	setvar VAR_HOF_BRAG_STATE, 1
@	msgbox FourIsland_House2_Text_WowHoFLowest
@	goto FourIsland_House2_EventScript_BraggedHoF
    end

FourIsland_House2_EventScript_BragHoFLow:: @ 81B2BE3
@	compare VAR_HOF_BRAG_STATE, 2
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedHoF
@	setvar VAR_HOF_BRAG_STATE, 2
@	msgbox FourIsland_House2_Text_WowHoFLow
@	goto FourIsland_House2_EventScript_BraggedHoF
    end

FourIsland_House2_EventScript_BragHoFHigh:: @ 81B2C01
@	compare VAR_HOF_BRAG_STATE, 3
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedHoF
@	setvar VAR_HOF_BRAG_STATE, 3
@	msgbox FourIsland_House2_Text_WowHoFHigh
@	goto FourIsland_House2_EventScript_BraggedHoF
    end

FourIsland_House2_EventScript_BragHoFHighest:: @ 81B2C1F
@	compare VAR_HOF_BRAG_STATE, 4
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedHoFMax
@	setvar VAR_HOF_BRAG_STATE, 4
@	msgbox FourIsland_House2_Text_WowHoFHighest
@	goto FourIsland_House2_EventScript_BraggedHoF
    end

FourIsland_House2_EventScript_AlreadyBraggedHoF:: @ 81B2C3D
@	msgbox FourIsland_House2_Text_ComeBackWithBetterStoryHoF
@	release
    end

FourIsland_House2_EventScript_AlreadyBraggedHoFMax:: @ 81B2C47
@	msgbox FourIsland_House2_Text_LivingLegendHoF
@	release
    end

FourIsland_House2_EventScript_BraggedHoF:: @ 81B2C51
@	textcolor 3
@	playfanfare MUS_LEVEL_UP
@	message FourIsland_House2_Text_HoFStickerApplied
@	waitmessage
@	waitfanfare
@	delay 90
@	release
    end

FourIsland_House2_EventScript_BragEggs:: @ 81B2C62
@	compare VAR_0x8005, 99
@	goto_if_le FourIsland_House2_EventScript_BragEggsLowest
@	compare VAR_0x8005, 199
@	goto_if_le FourIsland_House2_EventScript_BragEggsLow
@	compare VAR_0x8005, 299
@	goto_if_le FourIsland_House2_EventScript_BragEggsHigh
@	compare VAR_0x8005, 300
@	goto_if_ge FourIsland_House2_EventScript_BragEggsHighest
    end

FourIsland_House2_EventScript_BragEggsLowest:: @ 81B2C8F
@	compare VAR_EGG_BRAG_STATE, 1
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedEggs
@	setvar VAR_EGG_BRAG_STATE, 1
@	msgbox FourIsland_House2_Text_WowEggsLowest
@	goto FourIsland_House2_EventScript_BraggedEggs
    end

FourIsland_House2_EventScript_BragEggsLow:: @ 81B2CAD
@	compare VAR_EGG_BRAG_STATE, 2
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedEggs
@	setvar VAR_EGG_BRAG_STATE, 2
@	msgbox FourIsland_House2_Text_WowEggsLow
@	goto FourIsland_House2_EventScript_BraggedEggs
    end

FourIsland_House2_EventScript_BragEggsHigh:: @ 81B2CCB
@	compare VAR_EGG_BRAG_STATE, 3
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedEggs
@	setvar VAR_EGG_BRAG_STATE, 3
@	msgbox FourIsland_House2_Text_WowEggsHigh
@	goto FourIsland_House2_EventScript_BraggedEggs
    end

FourIsland_House2_EventScript_BragEggsHighest:: @ 81B2CE9
@	compare VAR_EGG_BRAG_STATE, 4
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedEggsMax
@	setvar VAR_EGG_BRAG_STATE, 4
@	msgbox FourIsland_House2_Text_WowEggsHighest
@	goto FourIsland_House2_EventScript_BraggedEggs
    end

FourIsland_House2_EventScript_AlreadyBraggedEggs:: @ 81B2D07
@	msgbox FourIsland_House2_Text_ComeBackWithBetterStoryEggs
@	release
    end

FourIsland_House2_EventScript_AlreadyBraggedEggsMax:: @ 81B2D11
@	msgbox FourIsland_House2_Text_LivingLegendEggs
@	release
    end

FourIsland_House2_EventScript_BraggedEggs:: @ 81B2D1B
@	textcolor 3
@	playfanfare MUS_LEVEL_UP
@	message FourIsland_House2_Text_EggStickerApplied
@	waitmessage
@	waitfanfare
@	delay 90
@	release
    end

FourIsland_House2_EventScript_BragLinkWins:: @ 81B2D2C
@	compare VAR_0x8006, 19
@	goto_if_le FourIsland_House2_EventScript_BragLinkWinsLowest
@	compare VAR_0x8006, 49
@	goto_if_le FourIsland_House2_EventScript_BragLinkWinsLow
@	compare VAR_0x8006, 99
@	goto_if_le FourIsland_House2_EventScript_BragLinkWinsHigh
@	compare VAR_0x8006, 100
@	goto_if_ge FourIsland_House2_EventScript_BragLinkWinsHighest
    end

FourIsland_House2_EventScript_BragLinkWinsLowest:: @ 81B2D59
@	compare VAR_LINK_WIN_BRAG_STATE, 1
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedLinkWins
@	setvar VAR_LINK_WIN_BRAG_STATE, 1
@	msgbox FourIsland_House2_Text_WowLinkWinsLowest
@	goto FourIsland_House2_EventScript_BraggedLinkWins
    end

FourIsland_House2_EventScript_BragLinkWinsLow:: @ 81B2D77
@	compare VAR_LINK_WIN_BRAG_STATE, 2
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedLinkWins
@	setvar VAR_LINK_WIN_BRAG_STATE, 2
@	msgbox FourIsland_House2_Text_WowLinkWinsLow
@	goto FourIsland_House2_EventScript_BraggedLinkWins
    end

FourIsland_House2_EventScript_BragLinkWinsHigh:: @ 81B2D95
@	compare VAR_LINK_WIN_BRAG_STATE, 3
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedLinkWins
@	setvar VAR_LINK_WIN_BRAG_STATE, 3
@	msgbox FourIsland_House2_Text_WowLinkWinsHigh
@	goto FourIsland_House2_EventScript_BraggedLinkWins
    end

FourIsland_House2_EventScript_BragLinkWinsHighest:: @ 81B2DB3
@	compare VAR_LINK_WIN_BRAG_STATE, 4
@	goto_if_eq FourIsland_House2_EventScript_AlreadyBraggedLinkWinsMax
@	setvar VAR_LINK_WIN_BRAG_STATE, 4
@	msgbox FourIsland_House2_Text_WowLinkWinsHighest
@	goto FourIsland_House2_EventScript_BraggedLinkWins
    end

FourIsland_House2_EventScript_AlreadyBraggedLinkWins:: @ 81B2DD1
@	msgbox FourIsland_House2_Text_ComeBackWithBetterStoryLinkWins
@	release
    end

FourIsland_House2_EventScript_AlreadyBraggedLinkWinsMax:: @ 81B2DDB
@	msgbox FourIsland_House2_Text_LivingLegendLinkWins
@	release
    end

FourIsland_House2_EventScript_BraggedLinkWins:: @ 81B2DE5
@	textcolor 3
@	playfanfare MUS_LEVEL_UP
@	message FourIsland_House2_Text_VictoryStickerApplied
@	waitmessage
@	waitfanfare
@	delay 90
@	release
    end

FourIsland_House2_EventScript_QuitBrag:: @ 81B2DF6
@	release
    end

@R
FourIsland_EventScript_ItemStarPiece:: @ 81BEC28
    finditem ITEM_STAR_PIECE
    end

FourIsland_EventScript_ItemStardust:: @ 81BEC35
    finditem ITEM_STARDUST
    end

OneIsland_KindleRoad_EventScript_ItemEther:: @ 81BEC42
    finditem ITEM_ETHER
    end

OneIsland_KindleRoad_EventScript_ItemMaxRepel:: @ 81BEC4F
    finditem ITEM_MAX_REPEL
    end

OneIsland_KindleRoad_EventScript_ItemCarbos:: @ 81BEC5C
	finditem ITEM_CARBOS
    end

FiveIsland_Meadow_EventScript_ItemMaxPotion:: @ 81BEC69
    finditem ITEM_MAX_POTION
    end

FiveIsland_Meadow_EventScript_ItemPPUp:: @ 81BEC76
    finditem ITEM_PP_UP
    end

FiveIsland_MemorialPillar_EventScript_ItemMetalCoat:: @ 81BEC83
    finditem ITEM_METAL_COAT
    end

SixIsland_OutcastIsland_EventScript_ItemPPUp:: @ 81BEC90
    finditem ITEM_PP_UP
    end

SixIsland_WaterPath_EventScript_ItemElixir:: @ 81BEC9D
    finditem ITEM_ELIXIR
    end

SixIsland_WaterPath_EventScript_ItemDragonScale:: @ 81BECAA
    finditem ITEM_DRAGON_SCALE
    end

SixIsland_RuinValley_EventScript_ItemFullRestore:: @ 81BECB7
    finditem ITEM_FULL_RESTORE
    end

SixIsland_RuinValley_EventScript_ItemHPUp:: @ 81BECC4
    finditem ITEM_HP_UP
    end

SixIsland_RuinValley_EventScript_ItemSunStone:: @ 81BECD1
    finditem ITEM_SUN_STONE
    end

SevenIsland_SevaultCanyon_EventScript_ItemKingsRock:: @ 81BECDE
    finditem ITEM_KINGS_ROCK
    end

SevenIsland_SevaultCanyon_EventScript_ItemMaxElixir:: @ 81BECEB
    finditem ITEM_MAX_ELIXIR
    end

SevenIsland_SevaultCanyon_EventScript_ItemNugget:: @ 81BECF8
    finditem ITEM_NUGGET
    end

ThreeIsland_BerryForest_EventScript_ItemMaxEther:: @ 81BED05
    finditem ITEM_MAX_ETHER
    end

ThreeIsland_BerryForest_EventScript_ItemFullHeal:: @ 81BED12
    finditem ITEM_FULL_HEAL
    end

ThreeIsland_BerryForest_EventScript_ItemMaxElixir:: @ 81BED1F
    finditem ITEM_MAX_ELIXIR
    end

MtEmber_Exterior_EventScript_ItemUltraBall:: @ 81BED2C
    finditem ITEM_ULTRA_BALL
    end

MtEmber_Exterior_EventScript_ItemFireStone:: @ 81BED39
    finditem ITEM_FIRE_STONE
    end

MtEmber_Exterior_EventScript_ItemDireHit:: @ 81BED46
    finditem ITEM_DIRE_HIT
    end

FourIsland_IcefallCave_1F_EventScript_ItemUltraBall:: @ 81BED53
    finditem ITEM_ULTRA_BALL
    end

FourIsland_IcefallCave_1F_EventScript_ItemHM07:: @ 81BED60
    finditem ITEM_HM07
    end

FourIsland_IcefallCave_B1F_EventScript_ItemFullRestore:: @ 81BED6D
    finditem ITEM_FULL_RESTORE
    end

FourIsland_IcefallCave_B1F_EventScript_ItemNeverMeltIce:: @ 81BED7A
    finditem ITEM_NEVER_MELT_ICE
    end

FiveIsland_RocketWarehouse_EventScript_ItemBigPearl:: @ 81BED87
    finditem ITEM_BIG_PEARL
    end

FiveIsland_RocketWarehouse_EventScript_ItemTM36:: @ 81BED94
    finditem ITEM_TM36
    end

FiveIsland_RocketWarehouse_EventScript_ItemPearl:: @ 81BEDA1
    finditem ITEM_PEARL
    end

FiveIsland_RocketWarehouse_EventScript_ItemUpGrade:: @ 81BEDAE
    finditem ITEM_UP_GRADE
    end

FiveIsland_LostCave_Room10_EventScript_ItemSilkScarf:: @ 81BEDBB
    finditem ITEM_SILK_SCARF
    end

FiveIsland_LostCave_Room11_EventScript_ItemLaxIncense:: @ 81BEDC8
    finditem ITEM_LAX_INCENSE
    end

FiveIsland_LostCave_Room12_EventScript_ItemSeaIncense:: @ 81BEDD5
    finditem ITEM_SEA_INCENSE
    end

FiveIsland_LostCave_Room13_EventScript_ItemMaxRevive:: @ 81BEDE2
    finditem ITEM_MAX_REVIVE
    end

FiveIsland_LostCave_Room14_EventScript_ItemRareCandy:: @ 81BEDEF
    finditem ITEM_RARE_CANDY
    end

SevenIsland_SevaultCanyon_House_EventScript_ItemLuckyPunch:: @ 81BEDFC
    finditem ITEM_LUCKY_PUNCH
    end

SilphCo_4F_EventScript_ItemTM41:: @ 81BEE09
    finditem ITEM_TM41
    end

VictoryRoad_2F_EventScript_DoubleEdgeTutor:: @ 81C47AE
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_DOUBLE_EDGE, EventScript_DoubleEdgeTaught
@	msgbox Text_DoubleEdgeTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_DoubleEdgeDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_DoubleEdgeDeclined
@	msgbox Text_DoubleEdgeWhichMon
@	setvar VAR_0x8005, MOVETUTOR_DOUBLE_EDGE
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_DoubleEdgeDeclined
@	setflag FLAG_TUTOR_DOUBLE_EDGE
@	goto EventScript_DoubleEdgeTaught
    end

EventScript_DoubleEdgeDeclined:: @ 81C4802
@	msgbox Text_DoubleEdgeDeclined
@	release
    end

EventScript_DoubleEdgeTaught:: @ 81C480C
@	msgbox Text_DoubleEdgeTaught
@	release
    end

EventScript_ThunderWaveTutor:: @ 81C4816
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_THUNDER_WAVE, EventScript_ThunderWaveTaught
@	msgbox Text_ThunderWaveTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_ThunderWaveDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_ThunderWaveDeclined
@	msgbox Text_ThunderWaveWhichMon
@	setvar VAR_0x8005, MOVETUTOR_THUNDER_WAVE
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_ThunderWaveDeclined
@	setflag FLAG_TUTOR_THUNDER_WAVE
@	goto EventScript_ThunderWaveTaught
    end

EventScript_ThunderWaveDeclined:: @ 81C486A
@	msgbox Text_ThunderWaveDeclined
@	release
    end

EventScript_ThunderWaveTaught:: @ 81C4874
@	msgbox Text_ThunderWaveTaught
@	release
    end

RockTunnel_B1F_EventScript_RockSlideTutor:: @ 81C487E
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_ROCK_SLIDE, EventScript_RockSlideTaught
@	msgbox Text_RockSlideTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_RockSlideDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_RockSlideDeclined
@	msgbox Text_RockSlideWhichMon
@	setvar VAR_0x8005, MOVETUTOR_ROCK_SLIDE
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_RockSlideDeclined
@	setflag FLAG_TUTOR_ROCK_SLIDE
@	goto EventScript_RockSlideTaught
    end

EventScript_RockSlideDeclined:: @ 81C48D2
@	msgbox Text_RockSlideDeclined
@	release
    end

EventScript_RockSlideTaught:: @ 81C48DC
@	msgbox Text_RockSlideTaught
@	release
    end

MtEmber_Exterior_EventScript_ExplosionTutor:: @ 81C48E6
	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_EXPLOSION, EventScript_ExplosionTaught
@	msgbox Text_ExplosionTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_ExplosionDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_ExplosionDeclined
@	msgbox Text_ExplosionWhichMon
@	setvar VAR_0x8005, MOVETUTOR_EXPLOSION
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_ExplosionDeclined
@	setflag FLAG_TUTOR_EXPLOSION
@	goto EventScript_ExplosionTaught
    msgbox Text_ExplosionTaught
    closemessage
	end

EventScript_ExplosionDeclined:: @ 81C493A
@	msgbox Text_ExplosionDeclined
@	release
    end

EventScript_ExplosionTaught:: @ 81C4944
@	msgbox Text_ExplosionTaught
@	release
    end

Route4_EventScript_MegaPunchTutor:: @ 81C494E
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_MEGA_PUNCH, EventScript_MegaPunchTaught
@	msgbox Text_MegaPunchTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MegaPunchDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MegaPunchDeclined
@	msgbox Text_MegaPunchWhichMon
@	setvar VAR_0x8005, MOVETUTOR_MEGA_PUNCH
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_MegaPunchDeclined
@	setflag FLAG_TUTOR_MEGA_PUNCH
@	goto EventScript_MegaPunchTaught
    end

EventScript_MegaPunchDeclined:: @ 81C49A2
@	msgbox Text_MegaPunchDeclined
@	release
    end

EventScript_MegaPunchTaught:: @ 81C49AC
@	msgbox Text_MegaPunchTaught
@	release
    end

Route4_EventScript_MegaKickTutor:: @ 81C49B6
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_MEGA_KICK, EventScript_MegaKickTaught
@	msgbox Text_MegaKickTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MegaKickDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MegaKickDeclined
@	msgbox Text_MegaKickWhichMon
@	setvar VAR_0x8005, MOVETUTOR_MEGA_KICK
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_MegaKickDeclined
@	setflag FLAG_TUTOR_MEGA_KICK
@	goto EventScript_MegaKickTaught
    end

EventScript_MegaKickDeclined:: @ 81C4A0A
@	msgbox Text_MegaKickDeclined
@	release
    end

EventScript_MegaKickTaught:: @ 81C4A14
@	msgbox Text_MegaKickTaught
@	release
    end

EventScript_DreamEaterTutor:: @ 81C4A1E
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_DREAM_EATER, EventScript_DreamEaterTaught
@	msgbox Text_DreamEaterTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_DreamEaterDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_DreamEaterDeclined
@	msgbox Text_DreamEaterWhichMon
@	setvar VAR_0x8005, MOVETUTOR_DREAM_EATER
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_DreamEaterDeclined
@	setflag FLAG_TUTOR_DREAM_EATER
@	goto EventScript_DreamEaterTaught
    end

EventScript_DreamEaterDeclined:: @ 81C4A72
@	msgbox Text_DreamEaterDeclined
@	release
    end

EventScript_DreamEaterTaught:: @ 81C4A7C
@	msgbox Text_DreamEaterTaught
@	release
    end

EventScript_SoftboiledTutor:: @ 81C4A86
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_SOFT_BOILED, EventScript_SoftboiledTaught
@	msgbox Text_SoftboiledTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SoftboiledDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SoftboiledDeclined
@	msgbox Text_SoftboiledWhichMon
@	setvar VAR_0x8005, MOVETUTOR_SOFT_BOILED
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_SoftboiledDeclined
@	setflag FLAG_TUTOR_SOFT_BOILED
@	goto EventScript_SoftboiledTaught
    end

EventScript_SoftboiledDeclined:: @ 81C4ADA
@	msgbox Text_SoftboiledDeclined
@	release
    end

EventScript_SoftboiledTaught:: @ 81C4AE4
@	msgbox Text_SoftboiledTaught
@	release
    end

FuchsiaCity_EventScript_SubstituteTutor:: @ 81C4AEE
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_SUBSTITUTE, EventScript_SubstituteTaught
@	msgbox Text_SubstituteTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SubstituteDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SubstituteDeclined
@	msgbox Text_SubstituteWhichMon
@	setvar VAR_0x8005, MOVETUTOR_SUBSTITUTE
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_SubstituteDeclined
@	setflag FLAG_TUTOR_SUBSTITUTE
@	goto EventScript_SubstituteTaught
    end

EventScript_SubstituteDeclined:: @ 81C4B42
@	msgbox Text_SubstituteDeclined
@	release
    end

EventScript_SubstituteTaught:: @ 81C4B4C
@	msgbox Text_SubstituteTaught
@	release
    end

SevenIsland_EventScript_SwordsDanceTutor:: @ 81C4B56
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_SWORDS_DANCE, EventScript_SwordsDanceTaught
@	msgbox Text_SwordsDanceTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SwordsDanceDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SwordsDanceDeclined
@	msgbox Text_SwordsDanceWhichMon
@	setvar VAR_0x8005, MOVETUTOR_SWORDS_DANCE
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_SwordsDanceDeclined
@	setflag FLAG_TUTOR_SWORDS_DANCE
@	goto EventScript_SwordsDanceTaught
    end

EventScript_SwordsDanceDeclined:: @ 81C4BAA
@	msgbox Text_SwordsDanceDeclined
@	release
    end

EventScript_SwordsDanceTaught:: @ 81C4BB4
@	msgbox Text_SwordsDanceTaught
@	release
    end

PewterCity_Museum_1F_EventScript_SeismicTossTutor:: @ 81C4BBE
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_SEISMIC_TOSS, EventScript_SeismicTossTaught
@	msgbox Text_SeismicTossTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SeismicTossDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_SeismicTossDeclined
@	msgbox Text_SeismicTossWhichMon
@	setvar VAR_0x8005, MOVETUTOR_SEISMIC_TOSS
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_SeismicTossDeclined
@	setflag FLAG_TUTOR_SEISMIC_TOSS
@	goto EventScript_SeismicTossTaught
    end

EventScript_SeismicTossDeclined:: @ 81C4C12
@	msgbox Text_SeismicTossDeclined
@	release
    end

EventScript_SeismicTossTaught:: @ 81C4C1C
@	msgbox Text_SeismicTossTaught
@	release
    end

EventScript_CounterTutor:: @ 81C4C26
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_COUNTER, EventScript_CounterTaught
@	msgbox Text_CounterTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_CounterDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_CounterDeclined
@	msgbox Text_CounterWhichMon
@	setvar VAR_0x8005, MOVETUTOR_COUNTER
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_CounterDeclined
@	setflag FLAG_TUTOR_COUNTER
@	goto EventScript_CounterTaught
    end

EventScript_CounterDeclined:: @ 81C4C7A
@	msgbox Text_CounterDeclined
@	release
    end

EventScript_CounterTaught:: @ 81C4C84
@	msgbox Text_CounterTaught
@	release
    end

EventScript_MetronomeTutor:: @ 81C4C8E
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_METRONOME, EventScript_MetronomeTaught
@	msgbox Text_MetronomeTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MetronomeDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MetronomeDeclined
@	msgbox Text_MetronomeWhichMon
@	setvar VAR_0x8005, MOVETUTOR_METRONOME
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_MetronomeDeclined
@	setflag FLAG_TUTOR_METRONOME
@	goto EventScript_MetronomeTaught
    end

EventScript_MetronomeDeclined:: @ 81C4CE2
@	msgbox Text_MetronomeDeclined
@	release
    end

EventScript_MetronomeTaught:: @ 81C4CEC
@	msgbox Text_MetronomeTaught
@	release
    end

EventScript_MimicTutor:: @ 81C4CF6
@	goto_if_set FLAG_TUTOR_MIMIC, EventScript_MimicTaught
@	msgbox Text_MimicTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MimicDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_MimicDeclined
@	msgbox Text_MimicWhichMon
@	setvar VAR_0x8005, MOVETUTOR_MIMIC
@	call EventScript_ChooseMoveTutorMon
@	lock
@	faceplayer
@	compare VAR_RESULT, 0
@	goto_if_eq EventScript_MimicDeclined
@	removeitem ITEM_POKE_DOLL, 1
@	setflag FLAG_TUTOR_MIMIC
@	goto EventScript_MimicTaught
    end

EventScript_MimicDeclined:: @ 81C4D4F
@	msgbox Text_MimicDeclined
@	release
    end

EventScript_MimicTaught:: @ 81C4D59
@	checkplayergender
@	compare VAR_RESULT, MALE
@	call_if_eq EventScript_MimicTaughtMale
@	compare VAR_RESULT, FEMALE
@	call_if_eq EventScript_MimicTaughtFemale
@	release
    end

EventScript_MimicTaughtMale:: @ 81C4D72
@	msgbox Text_MimicTaughtMale
@	return

EventScript_MimicTaughtFemale:: @ 81C4D7B
@	msgbox Text_MimicTaughtFemale
@	return

FourIsland_House1_EventScript_BodySlamTutor:: @ 81C4D84
@	lock
@	faceplayer
@	goto_if_set FLAG_TUTOR_BODY_SLAM, EventScript_BodySlamTaught
@	msgbox Text_BodySlamTeach, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_BodySlamDeclined
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq EventScript_BodySlamDeclined
@	msgbox Text_BodySlamWhichMon
@	setvar VAR_0x8005, MOVETUTOR_BODY_SLAM
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq EventScript_BodySlamDeclined
@	setflag FLAG_TUTOR_BODY_SLAM
@	goto EventScript_BodySlamTaught
    end

EventScript_BodySlamDeclined:: @ 81C4DD8
@	msgbox Text_BodySlamDeclined
@	release
    end

EventScript_BodySlamTaught:: @ 81C4DE2
@	msgbox Text_BodySlamTaught
@	release
    end

@.set LOCALID_CAPE_BRINK_TUTOR, 1

TwoIsland_CapeBrink_House_EventScript_StarterTutor:: @ 81C4DEC
@	goto_if_questlog EventScript_ReleaseEnd
@	special QuestLog_CutRecording
@	lock
@	faceplayer
@	goto_if_set FLAG_LEARNED_ALL_MOVES_AT_CAPE_BRINK, CapeBrinkTutor_EventScript_TaughtAllMoves
@	goto_if_set FLAG_TEMP_2, CapeBrinkTutor_EventScript_MoveJustTaught
@	getfirstpartymonname 0
@	msgbox Text_UltimateMoveThatMon
@	specialvar VAR_RESULT, CapeBrinkGetMoveToTeachLeadPokemon
@	compare VAR_RESULT, FALSE
@	goto_if_eq CapeBrinkTutor_EventScript_NoLeadStarter
@	copyvar VAR_0x8009, VAR_0x8005
@	compare VAR_FACING, DIR_NORTH
@	call_if_eq CapeBrinkTutor_EventScript_JumpInPlaceDown
@	compare VAR_FACING, DIR_SOUTH
@	call_if_eq CapeBrinkTutor_EventScript_JumpInPlaceUp
@	compare VAR_FACING, DIR_EAST
@	call_if_eq CapeBrinkTutor_EventScript_JumpInPlaceLeft
@	compare VAR_FACING, DIR_WEST
@	call_if_eq CapeBrinkTutor_EventScript_JumpInPlaceRight
@	msgbox Text_AllowMeToTeachMonUltimateMove, MSGBOX_YESNO
@	compare VAR_RESULT, NO
@	goto_if_eq CapeBrinkTutor_EventScript_DeclineMove
@	call EventScript_CanOnlyBeLearnedOnce
@	compare VAR_RESULT, NO
@	goto_if_eq CapeBrinkTutor_EventScript_DeclineMove
@	msgbox Text_LetMeConferUltimateMove
@	closemessage
@	fadescreen FADE_TO_BLACK
@	goto CapeBrinkTutor_EventScript_ChooseMon

@@ Unused
CapeBrinkTutor_EventScript_FadeTaughtMove:: @ 81C4E8F
@	fadescreen FADE_FROM_BLACK
@	goto CapeBrinkTutor_EventScript_TaughtMove
    end

CapeBrinkTutor_EventScript_MoveJustTaught:: @ 81C4E97
@	msgbox Text_MakeBestUseOfMove
@	release
    end

CapeBrinkTutor_EventScript_TaughtAllMoves:: @ 81C4EA1
@	msgbox Text_FeelRejuvenated
@	release
    end

CapeBrinkTutor_EventScript_TaughtMove:: @ 81C4EAB
@	copyvar VAR_0x8005, VAR_0x8009
@	specialvar VAR_RESULT, HasLearnedAllMovesFromCapeBrinkTutor
@	compare VAR_RESULT, TRUE
@	goto_if_eq CapeBrinkTutor_EventScript_LearnedAllMoves
@	msgbox Text_TaughtMove
@	setflag FLAG_TEMP_2
@	release
    end

CapeBrinkTutor_EventScript_LearnedAllMoves:: @ 81C4ECD
@	msgbox Text_PassedOnEverythingIKnow
@	setflag FLAG_LEARNED_ALL_MOVES_AT_CAPE_BRINK
@	release
    end

CapeBrinkTutor_EventScript_ChooseMon:: @ 81C4EDA
@	call EventScript_ChooseMoveTutorMon
@	compare VAR_RESULT, FALSE
@	goto_if_eq CapeBrinkTutor_EventScript_DeclineMove
@	goto CapeBrinkTutor_EventScript_TaughtMove
    end

CapeBrinkTutor_EventScript_JumpInPlaceDown:: @ 81C4EF0
@	applymovement LOCALID_CAPE_BRINK_TUTOR, Movement_JumpInPlaceDown
@	waitmovement 0
@	return

CapeBrinkTutor_EventScript_JumpInPlaceUp:: @ 81C4EFB
@	applymovement LOCALID_CAPE_BRINK_TUTOR, Movement_JumpInPlaceUp
@	waitmovement 0
@	return

CapeBrinkTutor_EventScript_JumpInPlaceLeft:: @ 81C4F06
@	applymovement LOCALID_CAPE_BRINK_TUTOR, Movement_JumpInPlaceLeft
@	waitmovement 0
@	return

CapeBrinkTutor_EventScript_JumpInPlaceRight:: @ 81C4F11
@	applymovement LOCALID_CAPE_BRINK_TUTOR, Movement_JumpInPlaceRight
@	waitmovement 0
@	return

CapeBrinkTutor_EventScript_DeclineMove:: @ 81C4F1C
@	msgbox Text_YouRejectIt
@	release
    end

CapeBrinkTutor_EventScript_NoLeadStarter:: @ 81C4F26
@	msgbox Text_JustMistaken
@	release
    end

EventScript_ChooseMoveTutorMon:: @ 81C4F30
@	special ChooseMonForMoveTutor
@	waitstate
@	lock
@	faceplayer
@	return

EventScript_CanOnlyBeLearnedOnce:: @ 81C4F37
@	textcolor 3
@	special DisableMsgBoxWalkaway
@	signmsg
@	msgbox Text_MoveCanOnlyBeLearnedOnce, MSGBOX_YESNO
@	normalmsg
@	call EventScript_RestorePrevTextColor
@	return

Movement_JumpInPlaceDown: @ 81C4F4C
@	jump_in_place_down
@	step_end

Movement_JumpInPlaceUp: @ 81C4F4E
@	jump_in_place_up
@	step_end

Movement_JumpInPlaceLeft: @ 81C4F50
@	jump_in_place_left
@	step_end

Movement_JumpInPlaceRight: @ 81C4F52
@	jump_in_place_right
@	step_end
TwoIsland_JoyfulGameCorner_EventScript_ShowDodrioBerryPickingRecords::
TwoIsland_JoyfulGameCorner_EventScript_ShowPokemonJumpRecords::
